<template>
	<view class="">
		<view class="topImg b-f p-b-30">
			<!-- <image src="/static/home/tu.png" class="tuParent" mode=""></image> -->
			<div v-if="obj.video">
				<video id="myVideo" class="tuParent" :src="obj.video" @error="videoErrorCallback" :poster="obj.cover"
					:danmu-list="danmuList" :autoplay="false" :show-fullscreen-btn="false"></video>
			</div>
			<view class="online">
				{{obj.title||'--'}}
			</view>
			<view class="intro m-t-10">
				简介：{{obj.intro||'--'}}
			</view>
		</view>
		<!-- 图文详情 -->
		<view class="botTit m-t-25 p-20 b-f">
			<view class="tuwen m-b-10">
				图文详情
			</view>
			<u-parse :html="obj.content"></u-parse>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				content: 'safdfnshdbhvnsdviubn',
				id: 0,
				obj: {}
			}
		},
		onLoad(options) {
			this.id = options.id
			this.initObj()
		},
		methods: {
			async initObj() {
				let n = await this.$api.ParentClass(this.id)
				this.obj = n.data
			}
		}
	}
</script>

<style lang="scss" scoped>
	.tuwen {
		font-size: 30rpx;
		font-family: PingFang SC, PingFang SC-Bold;
		font-weight: 700;
		text-align: left;
		color: #333333;
	}

	.topImg {
		padding-top: 15rpx;

		.tuParent {
			width: 100%;
			height: 360rpx;
			margin-bottom: 30rpx;
		}

		.online {
			font-size: 32rpx;
			font-family: PingFang SC, PingFang SC-Bold;
			font-weight: 700;
			padding-left: 25rpx;
			color: #333333;
		}

		.intro {
			font-size: 26rpx;
			font-family: PingFang SC, PingFang SC-Regular;
			font-weight: 400;
			padding-left: 25rpx;
			color: #999999;
		}
	}
</style>